package com.sxbbc.common.core.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.sxbbc.common.basics.utils.statics.StaticUtils;
import com.sxbbc.common.core.entity.jz.BMenus;
import com.sxbbc.common.core.mapper.jz.BMenusMapper;
import com.sxbbc.common.core.service.IBMenusService;

import java.util.List;

import org.springframework.stereotype.Service;

/**
 * <p>
 * 商家菜单表 服务实现类
 * </p>
 *
 * @author leehao
 * @since 2019-05-08
 */
@Service
public class BMenusServiceImpl extends ServiceImpl<BMenusMapper, BMenus> implements IBMenusService {

    @Override
    public List<BMenus> queryMenusList(QueryWrapper<BMenus> wrapper) {
        if (wrapper == null) {
            wrapper = new QueryWrapper<BMenus>();
        }
        wrapper.eq("status", StaticUtils.STATUS_YES);
        wrapper.orderByAsc("sort");
        return super.list(wrapper);
    }

}
